3.1 \(\int \csc (a+b x) \, dx\)

Optimal. Leaf size=12 \[ -\frac {\tanh ^{-1}(\cos (a+b x))}{b} \]

[Out]

-arctanh(cos(b*x+a))/b

________________________________________________________________________________________

Rubi [A]  time = 0.00, antiderivative size = 12, normalized size of antiderivative = 1.00, number of steps used = 1, number of rules used = 1, integrand size = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {3770} \[ -\frac {\tanh ^{-1}(\cos (a+b x))}{b} \]

Antiderivative was successfully verified.

[In]

Int[Csc[a + b*x],x]

[Out]

-(ArcTanh[Cos[a + b*x]]/b)

Rule 3770

Int[csc[(c_.) + (d_.)*(x_)], x_Symbol] :> -Simp[ArcTanh[Cos[c + d*x]]/d, x] /; FreeQ[{c, d}, x]

Rubi steps

\begin {align*} \int \csc (a+b x) \, dx &=-\frac {\tanh ^{-1}(\cos (a+b x))}{b}\\ \end {align*}

________________________________________________________________________________________

Mathematica [B]  time = 0.02, size = 38, normalized size = 3.17 \[ \frac {\log \left (\sin \left (\frac {a}{2}+\frac {b x}{2}\right )\right )}{b}-\frac {\log \left (\cos \left (\frac {a}{2}+\frac {b x}{2}\right )\right )}{b} \]

Antiderivative was successfully verified.

[In]

Integrate[Csc[a + b*x],x]

[Out]

-(Log[Cos[a/2 + (b*x)/2]]/b) + Log[Sin[a/2 + (b*x)/2]]/b

________________________________________________________________________________________

fricas [B]  time = 0.67, size = 30, normalized size = 2.50 \[ -\frac {\log \left (\frac {1}{2} \, \cos \left (b x + a\right ) + \frac {1}{2}\right ) - \log \left (-\frac {1}{2} \, \cos \left (b x + a\right ) + \frac {1}{2}\right )}{2 \, b} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(b*x+a),x, algorithm="fricas")

[Out]

-1/2*(log(1/2*cos(b*x + a) + 1/2) - log(-1/2*cos(b*x + a) + 1/2))/b

________________________________________________________________________________________

giac [A]  time = 0.17, size = 15, normalized size = 1.25 \[ \frac {\log \left ({\left | \tan \left (\frac {1}{2} \, b x + \frac {1}{2} \, a\right ) \right |}\right )}{b} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(b*x+a),x, algorithm="giac")

[Out]

log(abs(tan(1/2*b*x + 1/2*a)))/b

________________________________________________________________________________________

maple [A]  time = 0.04, size = 20, normalized size = 1.67 \[ -\frac {\ln \left (\csc \left (b x +a \right )+\cot \left (b x +a \right )\right )}{b} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(csc(b*x+a),x)

[Out]

-1/b*ln(csc(b*x+a)+cot(b*x+a))

________________________________________________________________________________________

maxima [A]  time = 0.32, size = 19, normalized size = 1.58 \[ -\frac {\log \left (\cot \left (b x + a\right ) + \csc \left (b x + a\right )\right )}{b} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(b*x+a),x, algorithm="maxima")

[Out]

-log(cot(b*x + a) + csc(b*x + a))/b

________________________________________________________________________________________

mupad [B]  time = 0.40, size = 12, normalized size = 1.00 \[ -\frac {\mathrm {atanh}\left (\cos \left (a+b\,x\right )\right )}{b} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/sin(a + b*x),x)

[Out]

-atanh(cos(a + b*x))/b

________________________________________________________________________________________

sympy [A]  time = 1.93, size = 37, normalized size = 3.08 \[ \begin {cases} - \frac {\log {\left (\cot {\left (a + b x \right )} + \csc {\left (a + b x \right )} \right )}}{b} & \text {for}\: b \neq 0 \\\frac {x \left (\cot {\relax (a )} \csc {\relax (a )} + \csc ^{2}{\relax (a )}\right )}{\cot {\relax (a )} + \csc {\relax (a )}} & \text {otherwise} \end {cases} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(b*x+a),x)

[Out]

Piecewise((-log(cot(a + b*x) + csc(a + b*x))/b, Ne(b, 0)), (x*(cot(a)*csc(a) + csc(a)**2)/(cot(a) + csc(a)), T
rue))

________________________________________________________________________________________